package com.qf.miaosha_service.controller;

import com.qf.miaosha_service.entity.JsonResult;
import com.qf.miaosha_service.service.SeckillService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/miaosha")
public class MiaoShaController {
    @Autowired
    private SeckillService seckillService;

    @RequestMapping("/miaosha")
    public JsonResult minaoShaBegin(Long flowerId) {
        Long userId = 1L;
        return seckillService.seckillBegin(flowerId, userId);

    }


}
